package Bussiness;

import Controller.Update;
import Model.BangDiem;
import Model.KhoaHoc;
import Model.LopHoc;
import Model.MonHoc;
import Model.SinhVien;
import Model.Users;

/**
 *
 * @author Nhóm java lớp PNV2T - Nguyễn Thị Lệ Đài - Nguyễn Chí Hướng
 */
public class Update_Action {
    Update up = null;
    /** Creates a new instance of Update_Action */
    public Update_Action() {
        up = new Update();
    }
    
    public boolean SuaLopHoc(LopHoc newlop){
        if (up.SuaLopHoc(newlop)>0)
            return true;
        return false;
    }
    
    public boolean SuaKhoaHoc(KhoaHoc newKH){
        if (up.SuaKhoaHoc(newKH)>0)
            return true;
        return false;
    }
    
    public boolean SuaSinhVien(SinhVien SV){
        if (up.SuaSinhVien(SV)>0)
            return true;
        return false;
    }
    
    public boolean SuaBangDiem(BangDiem diem){
        if (up.SuaBangDiem(diem)>0)
            return true;
        return false;
    }
    
    public boolean SuaMonHoc(MonHoc mon){
        if (up.SuaMonHoc(mon)>0)
            return true;
        return false;
    }
    
    public void Close(){
        up.CloseData();
    }

	public boolean SuaTaiKhoan(Users newTaiKhoan) {
		if (up.SuaTaiKhoan(newTaiKhoan)>0)
            return true;
        return false;
	}
    
}
